<!-- add.html -->
{% extends "base.html" %}

{% block content %}
<h2>新建记录</h2>
<form method="post">
    <div class="mb-3">
        <label class="form-label">类型</label>
        <select name="note_type" class="form-select">
            <option value="daily">每日</option>
            <option value="weekly">每周</option>
            <option value="monthly">每月</option>
        </select>
    </div>
    <div class="mb-3">
        <label class="form-label">日期</label>
        <input type="date" name="timestamp" class="form-control" required
               value="{{ datetime.now().strftime('%Y-%m-%d') }}">
    </div>
    <div class="mb-3">
        <label class="form-label">内容</label>
        <textarea name="content" class="form-control" rows="5" required></textarea>
    </div>
    <button type="submit" class="btn btn-primary">保存</button>
</form>
{% endblock %}
